import {get,post} from './request.js'


 const search=artistSearchFilter=>{
    return get('/artist',{params:artistSearchFilter})
}
const create=artist=>{
    return post('/artist',artist)
}

 const update=(id,fields)=>{
    return post(`/artist/${id}`,fields)
}

 const recommend=(id,recommendedFactor)=>{
    return post(`/artist/${id}/recommend`,{recommendedFactor})
}

 const cancelRecommendation=id=>{
    return post(`/artist/${id}/cancel_recommendation`)
}

export default {
    search,
    create,
    update,
    recommend,
    cancelRecommendation
}
















